<?php
error_reporting(E_ERROR);
ini_set("display_errors", true);

$debug = true;
include_once 'appinclude.php';
	
	$curr = 'myrides';
	include 'tabs.php';
?>
<br /><br />

<? 
	$rides = listRides(null, $facebook->profile_user);
	?>
	<div class="listTable">
		<? while($ride = mysql_fetch_assoc($rides) ){ ?>
			<div class="listRow">
				<? //print_debug($ride); ?>
				<img src="<?=APP_CALLBACK_URL?>images/hummer.jpg" alt="small car" style="float:left" />
				<div class="itemTitle">
					I am going to <?=$ride['dest_city'] . ', ' . $ride['dest_state']?>
					on <?=date("D, d M Y", strtotime($ride['departure_time']))?>
					at <?=date("h:ia", strtotime($ride['departure_time']))?>
				</div>
				<div class="itemDesc">
					<?=$ride['description']?>
				</div>
				<div>I have room for <?=$ride['seats_available']?> more people.</div>
				<br clear="all" />
			</div>
		<? } ?>
	</div>